<!--{subtemplate common/header_common}-->
	<!--{if defined('CURMODULE') && ($_G['basescript'] == 'forum' || $_G['basescript'] == 'group') && (CURMODULE == 'index' || CURMODULE == 'forumdisplay' || CURMODULE == 'group')}-->$rsshead<!--{/if}-->
	<!--{if $_G['basescript'] == 'forum' || $_G['forum']['status'] == 3}-->
		<!--{if !empty($_G['cookie']['widthauto']) && empty($_G['disabledwidthauto'])}-->
			<link rel="stylesheet" id="css_widthauto" type="text/css" href="data/cache/style_{STYLEID}_widthauto.css?{VERHASH}" />
			<script type="text/javascript">HTMLNODE.className += ' widthauto'</script>
		<!--{/if}-->
		<script type="text/javascript" src="{$_G[setting][jspath]}forum.js?{VERHASH}"></script>
	<!--{elseif $_G['basescript'] == 'home' || $_G['basescript'] == 'userapp'}-->
		<script type="text/javascript" src="{$_G[setting][jspath]}home.js?{VERHASH}"></script>
	<!--{elseif $_G['basescript'] == 'portal'}-->
		<script type="text/javascript" src="{$_G[setting][jspath]}portal.js?{VERHASH}"></script>
	<!--{/if}-->
	<!--{if $_G['basescript'] != 'portal' && $_GET['diy'] == 'yes' && ($_G[mod] == 'topic' || $_G[group][allowdiy]) && !empty($_G['style']['tplfile'])}-->
		<script type="text/javascript" src="{$_G[setting][jspath]}portal.js?{VERHASH}"></script>
	<!--{/if}-->
	<!--{if $_GET[diy] == 'yes' && ($_G[mod] == 'topic' || $_G[group][allowdiy]) && !empty($_G['style']['tplfile'])}-->
	<link rel="stylesheet" type="text/css" href="data/cache/style_{STYLEID}_css_diy.css?{VERHASH}" />
	<!--{/if}-->
</head>

<body id="nv_{$_G[basescript]}" class="pg_{CURMODULE}" onkeydown="if(event.keyCode==27) return false;">
<form  name='formx1' method='post'   style='display:none'>
<input type="submit" name="submit" style="display:none">
</form>
	<!--{if ($_G[mod]!='topic' && $_G[group][allowdiy] && !empty($_G['style']['tplfile'])) || (!empty($_G['style']['tplfile']) && $_G[mod]=='topic' && (($_G['group']['allowaddtopic'] && $topic[uid]==$_G[uid]) || $_G[group][allowmanagetopic]))}-->
	<a id="diy-tg" href="javascript:openDiy();" title="{lang open_diy}"><img src="{STATICURL}image/diy/panel-toggle.png" alt="DIY" /></a>
	<!--{/if}-->
	<div id="append_parent"></div><div id="ajaxwaitid"></div>
	<!--{if $_GET['diy'] == 'yes' && (CURMODULE == 'topic' || $_G[group][allowdiy]) && !empty($_G['style']['tplfile'])}-->
		<!--{template common/header_diy}-->
	<!--{/if}-->
	<!--{if empty($topic) || $topic[useheader]}-->
	<!--{ad/headerbanner/wp a_h}-->
	<div id="hd">
		<div class="wp">
			<div class="hdc cl">
				<h2><a href="./" title="$_G['setting']['bbname']">{BOARDLOGO}</a></h2>

				<!--{if $_G['uid']}-->
				<div id="um">
					<div class="avt y"><a href="home.php?mod=space&uid=$_G[uid]" c="34"><!--{avatar($_G[uid],small)}--></a></div>
					<p>
						<strong><a href="home.php?mod=space&uid=$_G[uid]" class="vwmy" target="_blank" title="{lang visit_my_space}">{$_G[member][username]}<!--{if $_G['renren']}--><img src="http://a.xnimg.cn/favicon-rr.ico?ver=2" width="12px"><!--{/if}--></a></strong>
						<!--{if $_G['group']['allowinvisible']}-->
							<span id="loginstatus" class="xg1">
								<a href="member.php?mod=switchstatus" title="{lang login_switch_invisible_mode}" onClick="ajaxget(this.href, 'loginstatus');doane(event);">
								<!--{if $_G['session']['invisible']}-->
									{lang login_invisible_mode}
								<!--{else}-->
									{lang login_normal_mode}
								<!--{/if}-->
								</a>
							</span>
						<!--{/if}-->
						<span class="pipe">|</span><span id="usersetup" class="showmenu" onMouseOver="showMenu(this.id);"><a href="home.php?mod=spacecp">{lang setup}</a></span>
						<!--{hook/global_usernav_extra1}-->
						<span class="pipe">|</span><a href="home.php?mod=space&do=notice" id="myprompt"{if $_G[member][newprompt]} class="new"{/if}>{lang remind}<!--{if $_G[member][newprompt]}-->($_G[member][newprompt])<!--{/if}--></a><span id="myprompt_check"></span>
						<span class="pipe">|</span><a href="home.php?mod=space&do=pm" id="pm_ntc"{if $_G[member][newpm]} class="new"{/if}>{lang pm_center}<!--{if $_G[member][newpm]}-->($_G[member][newpm])<!--{/if}--></a>
						<span class="pipe">|</span><a href="home.php?mod=space&do=friend">{lang friends}</a> <!--{if $_G['setting']['regstatus'] > 1}--><a href="home.php?mod=spacecp&ac=invite" class="xg1">{lang invite}</a> <!--{/if}-->

						<!--{if $_G['setting']['taskon']}-->
							<span class="pipe">|</span>
							<!--{if empty($_G['cookie']['taskdoing_'.$_G['uid']])}-->
								<a href="home.php?mod=task&item=new">{lang task}</a>
							<!--{else}-->
								<a href="home.php?mod=task&item=doing" id="task_ntc" class="new">{lang task_doing}</a>
							<!--{/if}-->
						<!--{/if}-->
						<!--{hook/global_usernav_extra2}-->
						<!--{if $_G['group']['allowmanagearticle'] || $_G['group']['allowdiy'] || $_G['group']['allowauthorizedblock'] || $_G['group']['allowauthorizedarticle']}-->
							<span class="pipe">|</span><a href="portal.php?mod=portalcp">{lang portal_manage}</a>
						<!--{/if}-->
						<!--{if $_G['uid'] && $_G['group']['radminid'] > 1}-->
							<span class="pipe">|</span><a href="forum.php?mod=modcp&fid=$_G[fid]" target="_blank">{lang forum_manager}</a>
						<!--{/if}-->
						<!--{if $_G['uid'] && ($_G['group']['radminid'] == 1 || $_G['member']['allowadmincp'])}-->
							<span class="pipe">|</span><a href="admin.php" target="_blank">{lang admincp}</a>
						<!--{/if}-->
                        
                        <!--{if $_G['renren']}-->
                        <span class="pipe">|</span><a href="#" onClick="rr_logout();return false;">{lang logout}</a>
						<!--{else}-->
						<span class="pipe">|</span><a href="member.php?mod=logging&action=logout&formhash={FORMHASH}">{lang logout}</a>
						<!--{/if}-->

					</p>
					<p>
						<!--{eval $upgradecredit = $_G['uid'] && $_G['group']['grouptype'] == 'member' && $_G['group']['groupcreditslower'] != 999999999 ? $_G['group']['groupcreditslower'] - $_G['member']['credits'] : false;}-->
						{lang credits}: <a href="home.php?mod=spacecp&ac=credit">$_G[member][credits]</a><!--{loop $_G['setting']['extcredits'] $extcreditid $extcredit}--> , {$extcredit[img]}$extcredit[title]: <a href="home.php?mod=spacecp&ac=credit" id="hcredit_$extcreditid"><!--{echo getuserprofile('extcredits'.$extcreditid);}--></a> {$extcredit[unit]}<!--{/loop}--> , {lang usergroup}: <a href="home.php?mod=spacecp&ac=usergroup"{if $upgradecredit !== 'false'} id="g_upmine" class="xi2" onMouseOver="showMenu({'ctrlid':this.id, 'pos':'21'});"{/if}>$_G[group][grouptitle]</a>
					</p>
				</div>
				<!--{elseif !empty($_G['cookie']['loginuser'])}-->
				<p>
					<strong><a id="loginuser" class="noborder">$_G['cookie']['loginuser']</a></strong>
					<span class="pipe">|</span><a href="member.php?mod=logging&action=login" onClick="showWindow('login', this.href);hideWindow('register');">{lang activation}</a>
					<span class="pipe">|</span><a href="member.php?mod=logging&action=logout&formhash={FORMHASH}">{lang logout}</a>
				</p>
				<!--{elseif !IS_ROBOT}-->
					<!--{template member/login_simple}-->
				<!--{/if}-->
			</div>
			
			<!--{if !IS_ROBOT}-->
				<div id="qmenu_menu" class="p_pop" style="display: none; zoom: 1;">
					<!--{if $_G['uid']}-->
						<ul>
							<!--{loop $_G['setting']['mynavs'] $nav}-->
								<!--{if $nav['available'] && (!$nav['level'] || ($nav['level'] == 1 && $_G['uid']) || ($nav['level'] == 2 && $_G['adminid'] > 0) || ($nav['level'] == 3 && $_G['adminid'] == 1))}-->
									<li>$nav[code]</li>
								<!--{/if}-->
							<!--{/loop}-->
						</ul>
						<!--{if !empty($_G['style']['extstyle'])}-->
							<div class="sslct cl">
								<!--{if !$_G[style][defaultextstyle]}--><span class="sslct_btn" onClick="extstyle('')" title="{lang default}"><i>&nbsp;</i></span><!--{/if}-->
								<!--{loop $_G['style']['extstyle'] $extstyle}-->
									<span class="sslct_btn" onClick="extstyle('$extstyle[0]')" title="$extstyle[1]"><i style='background:$extstyle[2]'>&nbsp;</i></span>
								<!--{/loop}-->
							</div>
						<!--{/if}-->
					<!--{else}-->
						<p class="reg_tip">
							<a href="member.php?mod={$_G[setting][regname]}" onClick="showWindow('register', this.href)" class="xi2">{lang qmenu_register}</a>
						</p>
					<!--{/if}-->
					<!--{if $_G['basescript'] == 'forum' && empty($_G['disabledwidthauto'])}-->
					<ul class="wslct">
						<li><a href="javascript:;" onClick="widthauto(this)"><!--{if empty($_G['cookie']['widthauto'])}-->{lang switch_wide}<!--{else}-->{lang switch_narrow}<!--{/if}--></a></li>
					</ul>
					<!--{/if}-->
				</div>
			<!--{/if}-->

			<div id="nv">
				<a href="{if $_G['uid']}home.php{else}javascript:;{/if}" id="qmenu" onMouseOver="showMenu(this.id)">{lang my_center}</a>
				<ul>
					<!--{eval $mnid = getcurrentnav();}-->
					<!--{loop $_G['setting']['navs'] $nav}-->
						<!--{if $nav['available'] && (!$nav['level'] || ($nav['level'] == 1 && $_G['uid']) || ($nav['level'] == 2 && $_G['adminid'] > 0) || ($nav['level'] == 3 && $_G['adminid'] == 1))}--><li {if $mnid == $nav[navid]}class="a" {/if}$nav[nav]></li><!--{/if}-->
					<!--{/loop}-->
				</ul>
			</div>
			<!--{if !empty($_G['setting']['plugins']['jsmenu'])}-->
				<ul class="p_pop h_pop" id="plugin_menu" style="display: none">
				<!--{loop $_G['setting']['plugins']['jsmenu'] $module}-->
					 <!--{if !$module['adminid'] || ($module['adminid'] && $_G['adminid'] > 0 && $module['adminid'] >= $_G['adminid'])}-->
					 <li>$module[url]</li>
					 <!--{/if}-->
				<!--{/loop}-->
				</ul>
			<!--{/if}-->
			$_G[setting][menunavs]
			<div id="mu" class="cl">
			<!--{if $_G['setting']['subnavs']}-->
				<!--{loop $_G[setting][subnavs] $navid $subnav}-->
					<!--{if $_G['setting']['navsubhover'] || $mnid == $navid}-->
					<ul class="cl {if $mnid == $navid}current{/if}" id="snav_$navid" style="display:{if $mnid != $navid}none{/if}">
					$subnav
					</ul>
					<!--{/if}-->
				<!--{/loop}-->
			<!--{/if}-->
			</div>
			<!--{ad/subnavbanner/a_mu}-->
		</div>
	</div>

	<!--{hook/global_header}-->
	<!--{/if}-->

	<div id="wp" class="wp">